<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Бланк Почты России</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<base href="{$smarty.const.CONF_FULL_SHOP_URL}" />
<link rel="stylesheet" href="{$smarty.const.URL_CSS}/printforms.css" type="text/css" />
<style type="text/css">{literal}
html, body, p {
	padding:0;
	margin: 0;
}
input, div {
	margin: 5px;
	margin-top:15px;
}
#img-link {
	width:auto;
	outline: none;
	padding:0;
	display:inline;
}
img {
	border-width:0;
	padding: 0;
	margin: 0;
}
</style>{/literal}
<script type="text/javascript">{literal}
<!--
function show(node,hide_id,show_id){
	var hide_node;
	if(hide_node = document.getElementById(hide_id)){
		hide_node.style.display = 'none';
	}
	var load_node
	if(load_node = document.getElementById('load_div')){
		load_node.style.display = '';
	}
	var image_node;
	if(image_node = document.getElementById('image')){
		image_node.src = node.href;
		image_node.style.display = 'none';
	image_node.parentNode.href = node.href;
	image_node.parentNode.style.display = 'none';
		image_node.onload = function(){load(show_id);}
	}
	return false;
}

function load(show_id){
	var show_node
	if(show_node = document.getElementById(show_id)){
		show_node.style.display = '';
	}
	var image_node;
	if(image_node = document.getElementById('image')){
		image_node.style.display = '';
	image_node.parentNode.style.display = 'block';
	}
	var load_node
	if(load_node = document.getElementById('load_div')){
		load_node.style.display = 'none';
	}
}
//-->{/literal}
</script>
</head>
<body>
{if $editable}
<form id="edit_front_form" action="{"side=print&action=$action"|set_query_html}" method="post">
<table>
	<tr><td colspan="2"><h2>Корректировка отображаемых данных:</h2></td></tr>
	<tr>
		<td>Сумма объявленной ценности</td>
		<td><input size="80" type="text" name="order_price"
			value="{$order.order_price|escape:'html'}" /></td>
	</tr>
	<tr>
		<td>Сумма наложенного платежа</td>
		<td><input size="80" type="text" name="order_amount"
			value="{$order.order_amount|escape:'html'}" /></td>
	</tr>
	<tr>
		<td>Сумма объявленной ценности (цифрами)</td>
		<td><input type="text" name="order_price_d"
			value="{$order.order_price_d|escape:'html'}" /></td>
	</tr>
	<tr>
		<td>Сумма наложенного платежа (цифрами)</td>
		<td><input type="text" name="order_amount_d"
			value="{$order.order_amount_d|escape:'html'}" /></td>
	</tr>
	<tr>
		<td>Получатель заказа</td>
		<td><input size="80" type="text" name="shipping_name"
			value="{$order.shipping_name|escape:'html'}" /></td>
	</tr>
	<tr>
		<td>Адрес (строка 1)</td>
		<td><input size="80" type="text" name="shipping_address_1"
			value="{$order.shipping_address_1|escape:'html'}" /></td>
	</tr>
	<tr>
		<td>Адрес (строка 2)</td>
		<td><input size="80" type="text" name="shipping_address_2"
			value="{$order.shipping_address_2|escape:'html'}" /></td>
	</tr>
	<tr>
		<td>Почтовый индекс</td>
		<td><input type="text" name="shipping_zip"
			value="{$order.shipping_zip|escape:'html'}" /></td>
	</tr>
{*	<tr>
		<td>Отправитель</td>
		<td><input type="text" name="COMPANY_NAME"
			value="{$order.COMPANY_NAME|escape:'html'}" /></td>
	</tr>
	<tr>
		<td>Адрес (строка 1)</td>
		<td><input type="text" name="ADDRESS_1"
			value="{$order.ADDRESS_1|escape:'html'}" /></td>
	</tr>
	<tr>
		<td>Адрес (строка 2)</td>
		<td><input type="text" name="ADDRESS_1"
			value="{$order.ADDRESS_1|escape:'html'}" /></td>
	</tr>
	<tr>
		<td>Почтовый индекс</td>
		<td><input type="text" name="POST_CODE"
			value="{$order.POST_CODE|escape:'html'}" /></td>
	</tr>*}
	<tr>
		<td>&nbsp;</td>
		<td><input type="submit" value="Просмотр" /></td>
	</tr>
</table>
</form>
{else}
{include file="print_button.html"} {*relative path from frontend*}
<div id="front_div" class="noprint" style="display:none;"><span
	style="background-color: #ffc" class="noprint">Лицевая сторона
ф. 116</span> | <a href="{"action=&side=back&action=$action"|set_query_html}" title=""
	class="noprint" onclick="return show(this,'front_div','back_div');">Оборот
ф.116</a> 
</div>

<div id="back_div" class="noprint" style="display:none;"><a
	id="edit_front_link" href="{"action=&side=front&action=$action"|set_query_html}"
	title="" class="noprint"
	onclick="return show(this,'back_div','front_div');">Лицевая сторона
ф. 116</a> | <span style="background-color: #ffc" class="noprint">Оборот
ф.116</span></div>

<div id="load_div" class="noprint"
	style="background-image: url('{$smarty.const.CONF_WAROOT_URL}{if !$smarty.const.CONF_ON_WEBASYST}published/{/if}SC/html/scripts/images_common/loading.gif');background-repeat: no-repeat;height:32px;padding-left: 40px;padding-top: 8px;padding-bottom: 16px;background-position: 0 50%">Подождите,
идет загрузка...</div>
<p>
<a href="{"action=&side=front&action=$action"|set_query_html}" target="_blank" title="" style="display:none;border:0" >
<img width="100%" id="image" src="{"action=&side=front&action=$action"|set_query_html}" alt=""	title="" onload="load('front_div');" />
</a>
</p>
{/if}
</body>
</html>